<!-- 公用文本图文列表 -->
<!-- 
	该组件用于 提现明细、我的分享、我的返利、我的好友等文本图文明细
	
	images 有该值时会在左则显示图片
	background 可改变文本颜色及 num 的背景色
	types 可自由传文本内容
 -->
<template>
	<view class="text_item" :class="item.images? 'images':''">
		<img v-if="!types" :src="item.images" class="imagesbox"/>
		<view class="title">{{item.title}}</view>
		<view class="time_type_box">
			<view class="type" v-if="types" :style="[{color:background}]">{{types}}</view>
			<view class="time">{{item.time}}</view>
			<view class="num" :style="[{background:background}]">{{item.num}}</view>
		</view>
	</view>
</template>

<script>
</script>

<style lang="scss">
	.text_item {
		width:100%; border-bottom:1px solid #eeeeee; padding:26upx;
		&.images { padding-left:116upx; position:relative; }
		.imagesbox { width:74upx; height:74upx; position:absolute; left:26upx; top:26upx; border-radius:37upx; }
		.title { width:100%; height:40upx; line-height:32upx; color:$font-color-999; font-size:$font-base; overflow:hidden; white-space:nowrap; text-overflow:ellipsis; }
		.time_type_box {
			width:100%; height:38upx;
			.type { 
				display:block; float:left; font-size:$font-sm; padding-right:38upx; position:relative;
				&:before { width:38upx; height:38upx; line-height:38upx; display:block; font-size:$font-lg + 8upx; color:$font-color-333; text-align:center; content:"·"; position:absolute; right:0px; top:0px; }
			}
			
			.time { display:block; float:left; font-size:$font-sm; color:$font-color-ccc; }
			.num { height:38upx; line-height:42upx; border-radius:48upx; padding:0 18upx; display:block; float:right; font-size:$font-sm; color:$bgcolor_white; }
		}
	}
</style>

<script>
export default {
	data() {
		return {

		}
	},
	props:{
		item:{
			type: Object
		},
		types:{
			type: String,
			default: ''
		},
		background: {
			type: String,
			default: '#FF0036'
		},
	},
	methods: {

	},
}
</script>